﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Reflection;

namespace MusicPlugin.Code
{
    public static class Global
    {
        public static string TRACK_INDEX = "{track}";
        public static string TITLE_INDEX = "{title}";
        public static string ARTIST_INDEX = "{artist}";
        public static string ALBUM_INDEX = "{album}";
        public static string DIALOG_HEADING = "MusicPlugin";
        public static string LYRICSFLY_ACCESS_KEY = "841a66a0ca9c8584b-temporary.API.access";
        public static string LYRICSFLY_URL_ARTIST_TITLE = @"http://api.lyricsfly.com/api/api.php?i="+LYRICSFLY_ACCESS_KEY+"&a={0}&t={1}";
        //http://api.lyricsfly.com/api/api.php?i=841a66a0ca9c8584b-temporary.API.access&a=50 Cent&t=U Not Like Me
        public static string PLUGIN_NAME = "Music support.";
        public static string PLUGIN_DESCRIPTION = "Music library plugin for MediaBrowser by Nephelyn.";
        public static System.Version PLUGIN_VERSION = Assembly.GetExecutingAssembly().GetName().Version;
        public static System.Version PLUGIN_REQUIRED_MB_VERSION = new System.Version(2, 2, 2, 0);
        public static System.Version PLUGIN_TESTED_MB_VERSION = new System.Version(2, 2, 2, 0);
        public static bool PLUGIN_IS_CONFIGURABLE = true;
        public static string PLUGIN_RICHURL = @"http://www.craigthomas.co.za/MusicPlugin/MusicPlugin.html";

        private static List<string> _indexes;
        public static List<string> Indexes
        {
            get
            {
                if (_indexes == null)
                {
                    _indexes = new List<string>();
                    _indexes.Add(TRACK_INDEX);
                    _indexes.Add(TITLE_INDEX);
                    _indexes.Add(ARTIST_INDEX);
                    _indexes.Add(ALBUM_INDEX);
                }
                return _indexes;
            }
        }

        public static readonly Guid MUSIC_ITUNES_GUID = new Guid("{97581452-7374-11DE-B53C-716855D89593}");
        public static readonly Guid MUSIC_NORMAL_GUID = new Guid("{D0DAD4BA-90B8-11DE-9AC9-06AC55D89593}");
    }
}
